package com.jr.controller;

import com.jr.service.ParkingRecordsVehiclesService;
import com.jr.vo.ParkingRecordsVehicles;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import javax.annotation.Resource;
import java.util.List;

/**
 * 车辆和停车记录关联查询控制器
 */
@RestController
@RequestMapping("/api/parking-records-vehicles")
public class ParkingRecordsVehiclesController {
    
    @Resource
    private ParkingRecordsVehiclesService parkingRecordsVehiclesService;
    
    /**
     * 查询今天的停车记录和车辆信息
     * @return 今天的停车记录和车辆信息列表
     */
    @GetMapping("/today")
    public List<ParkingRecordsVehicles> findTodayParkingRecordsVehicles() {
        return parkingRecordsVehiclesService.findTodayParkingRecordsVehicles();
    }
}